﻿<!DOCTYPE HTML>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>CSS3 checkbox</title>
    <link href="style.css" rel="stylesheet" />
    <style type="text/css">
        .demo {
            width: 560px;
            margin: 60px auto 10px auto;
        }

        .wrap {
            margin: 30px 0;
        }

            .wrap p {
                padding: 10px 0;
            }
    </style>
</head>

<body>
    <div id="main">
        <div class="demo">
            <div class="wrap">
                <p>1. 勾选</p>
                <input type="checkbox" id="chk-base-1" class="chk_base" checked /><label for="chk-base-1"></label>
                <input type="checkbox" id="chk-base-2" class="chk_base" /><label for="chk-base-2"></label>
            </div>
            <div class="wrap" style="width:198px">
                <p>2. 单按钮</p>
                <input type="checkbox" id="checkbox_b1" class="chk_2" /><label for="checkbox_b1">我同意</label>
            </div>

            <div class="wrap" style="width: 180px;">
                <p>3. 移动端开关</p>
                <input type="checkbox" id="checkbox_c1" class="chk_3" /><label for="checkbox_c1"></label>
                <input type="checkbox" id="checkbox_c2" class="chk_3" checked /><label for="checkbox_c2"></label>
            </div>

            <div class="wrap" style="width: 231px;">
                <p>4. 开启和关闭</p>
                <input type="checkbox" id="checkbox_d1" class="chk_4" /><label for="checkbox_d1"></label>
                <input type="checkbox" id="checkbox_d2" class="chk_4" checked /><label for="checkbox_d2"></label>
            </div>
        </div>
    </div>
</body>
</html>
